import request from '@/utils/request'

// 查询比对结果列表
export function listResult(checkId) {
  return request({
    url: '/system/result/list?checkId='+checkId,
    method: 'get',
  })
}
// 查询比对结果详细
export function getResult(query) {
  return request({
    url: '/system/resultDetail/list',
    method: 'get',
    params: query
  })
}
// 查询比对结果详细
export function formExist(id) {
  return request({
    url: '/system/resultDetail/formExist?id='+id,
    method: 'get'
  })
}

// 预览结果文件
export function previewResult(id) {
  return request({
    responseType: "blob",
    url: 'system/file/preview?id='+id,
    method: 'get',
  })
}

// 预览结果文件
export function previewForm(id) {
  return request({
    responseType: "blob",
    url: 'system/file/previewForm?id='+id,
    method: 'get',
  })
}
// 预览结果文件
export function previewForm1(id) {
  return request({
    responseType: "blob",
    url: 'system/file/previewForm1?id='+id,
    method: 'get',
  })
}

// 下载比对结果文件
export function downLoadResult() {
  return request({
    url: '/system/file/downLoad',
    method: 'get',
    responseType: "blob",
  })
}

// 预览结果文件
export function previewResult1(id) {
  return request({
    responseType: "blob",
    url: 'system/file/preview1?id='+id,
    method: 'get',
  })
}

// 删除比对结果
export function delResult(id) {
  return request({
    url: '/system/result/' + id,
    method: 'delete'
  })
}
